{  Statement: http://acmp.ru/?main=task&id_task=264
   Verdict: Accepted
}
uses
    SysUtils, Math;

var
    i,n,k,ans,cur:longint;

begin
reset(input,'input.txt');
rewrite(output,'output.txt');
read(n);
ans := 0;
cur := 0;
for i:=1 to n do begin
    read(k);
    if k > 0 then inc(cur);
    if (k <= 0) or (i = n) then begin
        ans := max(ans, cur);
        cur := 0;
    end;
end;
write(ans);
end.
